# Contributor: Bart Ribbers <bribbers@disroot.org>
# Maintainer: Bart Ribbers <bribbers@disroot.org>
pkgname=krusader
pkgver=2.8.0
pkgrel=1
# armhf blocked by extra-cmake-modules
arch="all !armhf"
url="https://apps.kde.org/krusader"
pkgdesc="Advanced twin panel (commander style) file manager"
license="GPL-2.0-or-later and GFDL-1.1-or-later"
makedepends="
	extra-cmake-modules
	karchive5-dev
	kbookmarks5-dev
	kcodecs5-dev
	kcompletion5-dev
	kconfig5-dev
	kcoreaddons5-dev
	kdoctools5-dev
	kguiaddons5-dev
	ki18n5-dev
	kiconthemes5-dev
	kio5-dev
	kitemviews5-dev
	knotifications5-dev
	kparts5-dev
	ktextwidgets5-dev
	kwallet5-dev
	kwidgetsaddons5-dev
	kwindowsystem5-dev
	kxmlgui5-dev
	qt5-qtbase-dev
	samurai
	solid5-dev
	"
source="https://download.kde.org/stable/krusader/$pkgver/krusader-$pkgver.tar.xz"
subpackages="$pkgname-doc $pkgname-lang"

build() {
	cmake -B build -G Ninja \
		-DCMAKE_BUILD_TYPE=MinSizeRel \
		-DCMAKE_INSTALL_PREFIX=/usr \
		-DCMAKE_INSTALL_LIBDIR=lib
	cmake --build build
}

check() {
	cd build
	CTEST_OUTPUT_ON_FAILURE=TRUE ctest
}

package() {
	DESTDIR="$pkgdir" cmake --install build
}

sha512sums="
40a8736e91756153c649defaaef956f4d65664b4a86e64f861f34744980cdebb2da8d31f596fdc53ea911a7b7ea1a4f1875b8e564976770558bf64e77ff25583  krusader-2.8.0.tar.xz
"
